Multimedia extensions (MMEs) have become one of the most popular additions to general-purpose processors. Existing multimedia extensions can be characterized as Single Instruction Multiple Datapath (SIMD) units that support packed fixed-length vectors. The traditional programming model for multimedia extensions has been explicit vector or array programming using either (in-line) assembly or intrinsic functions embedded in a high-level programming language. However, such array-based programs create runtime penalties for a processor due to unaligned loads from memory in SIMD operations. The array-based programs may include aligned code and unaligned code. Aligned code means that desired data resides at an address that is a multiple of a vector register size. Memory penalties due to crossing multiple memory blocks may be prevented when code is aligned.
Furthermore, processors have a number of registers (e.g., 32-bit registers) that perform certain functions. For example, some registers may address memory locations that are offset by a multiple of common offsets. However, the array-based programs cause stack spills and refills of such registers, which inflicts penalties on a processor.